import { axios } from '@/utils/request'

const api = {
  psUserProductAct: '/user/productact'
}

export function getPsUserProductActList (parameter) {
  return axios({
    url: api.psUserProductAct + '/list',
    method: 'get',
    params: parameter
  })
}

export function savePsUserProductAct (parameter) {
  return axios({
    url: api.psUserProductAct + (parameter.userId > 0 ? '/update' : '/save'),
    method: 'post',
    data: parameter,
    headers: {
      'Content-Type': 'application/json;charset=UTF-8'
    }
  })
}

export function delPsUserProductAct (parameter) {
  return axios({
    url: api.psUserProductAct + '/remove',
    method: 'post',
    params: parameter
  })
}

export const psUserProductActExport = api.psUserProductAct + '/export'
